<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <!-- <script src="https://cdn.jsdelivr.net/npm/vue@2/dist/vue.js"></script> -->
  <script src="./node_modules/vue/dist/vue.js"></script>
</head>

<body>
  <div id="app">
    <h2 v-bind:title="title">{{msg}}</h2>
    <h2 :title="title">{{msg}}</h2>
  </div>

  <script>
    // v-bind 绑定属性 v-bind:属性="data中的值"
    // 简写是 冒号
    const app = new Vue({
      el: "#app",
      data: {
        msg: "hello vue!",
        title: "my title!"
      }
    })
  </script>

</body>

</html>
